I am having trouble figuring out the correct Syntax for the File Path
SELECT c1.Produkt,c2.Name
from Reservation c1
left join [Articles.mdb].[Articles] c2 on c1.Produkt=c2.Produkt
group by c1.Produkt,c2.Name
It now searches for the Articles.mdb inside the Application Folder . I would like to specify the path , for example c:\database\articles.mdb . But unfortunately I cannot figure it out how to do it.
I tried [c:\database\articles.mdb] and ['c:\database\articles.mdb'] , either get Incorrect Parameter, or Incorrect Filename .
Please help.
UPDATE :
after removing Parameter Check from TADOQuery . And entering the text like this :
left join [c:\Articles.mdb].[Articles] c2 on c1.Produkt=c2.Produkt
It works.
Related
I can't figure out how to copy from vim, and paste to another console tab.
For instance, I'm using the preconfigured nvimdocker / ansible-neovim-pyright container. I did try:
set mouse= I can copy/paste with middle click, but I get the column with line numbers in the clipboard. Makes it unpracticable to copy few lines of script.
set mouse=nv This is great, I can select the text without the line numbers. Potentially right-click->Copy. But none of the * (highlight clipboard) nor + (system clipboard) registers are working. (None of the middle-click or explicit paste will work).
Obviously, it's not possible to access the system clipboard from remote, and xclip cannot help. I think the problem is similar when using a remote nvim through SSH (with no X redirection).
But how could I have the 'highlight' clipboard ? Is there maybe a (n)vim command to temporarily disable the left column with numbers/git/modifs/coc-errors ?
Thanks,
This works:
curl 'https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/pub?gid=911257845&single=true&output=csv'
however I want to only pick up rows where count > 300.
The query before encoding would be
select * where F > 300
After encoding
select%20*%20where%20F%3E300
So the url becomes
https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/pub?gid=911257845&output=csv&tq=select%20*%20where%20F%3E300
The line above works retrieves a file, but it returns the whole file, and doesn't filter.
Note that a published web sheet has the form
https://docs.google.com/spreadsheets/d/e/KEY/pub?gid=GID
https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/pub?gid=911257845
This works. Adding &output=csv to it (no space before the &) works, and it downloads as a csv file. This opens in excel and shows the data in the table.
I tried this:
https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/pub?gid=911257845&output=csv&tq=select%20*%20where%20F%3E%20300
and
https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/gviz/tq?gid=911257845&output=csv&tq=select%20*%20where%20F%3E300
and get errors -- resource not available.
The page above should be public for people who want to try.
This may be an issue between publishing a sheet, and sharing a whole spread sheet to anyone who has the link.
I've created a new page that uses importrange() that slurps up the page from the main sheet, and that one is public.
https://docs.google.com/spreadsheets/d/1-lqLuYJyHAKix-T8NR8wV8ZUUbVOJrZTysccid2-ycs/edit?usp=sharing
How about this modification?
Modification points :
When it uses query, please use like https://docs.google.com/spreadsheets/d/### file ID ###/gviz/tq?gid=###&tq=### query ###.
When select%20*%20where%20%F%3E300 is decoded, it is select * where %F>300.
select * where F > 300 is select%20%2a%20where%20F%20%3e%20300.
In order to output CSV, please use tqx=out:csv.
Please share the Spreadsheet.
On Google Drive
On the Spreadsheet file
right-click -> Share -> Advanced -> Click "change" at "Private - Only you can access"
Check "On Anyone with the link"
Click "Save"
At "Link to share", copy URL.
Retrieve file ID from https://docs.google.com/spreadsheets/d/### file ID ###/edit?usp=sharing
Modified curl command :
curl 'https://docs.google.com/spreadsheets/d/### file ID ###/gviz/tq?gid=911257845&tq=select%20%2a%20where%20F%20%3e%20300&tqx=out:csv'
Reference :
Query Language Reference
If I misunderstand your question, I'm sorry.
Edit :
The following 2 URLs are the comparison between your URL and my answer. The URL of my answer was matched to your URL.
1. Your URL
https://docs.google.com/spreadsheets/d/e/2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc/gviz/tq?gid=911257845&output=csv&tq=select%20*%20where%20F%3E300
When above URL is separated,
https://docs.google.com/spreadsheets/d/e/
e/ is not required.
2PACX-1vS3iBtVf4i_won5zAN9NGPqhcd6CcTb-4QHxpisSjCmlgV95B6mFmZvtMaC9GPvD7m8kD-6XLkVAhfc
This is not the file ID of spreadsheet.
/gviz/tq
gid=911257845
output=csv
tq=select%20*%20where%20F%3E300
2. In my answer matched to your URL
https://docs.google.com/spreadsheets/d/### file ID ###/gviz/tq?gid=###&tqx=out:csv&tq=### query ###
When above URL is separated,
https://docs.google.com/spreadsheets/d/
### file ID ###
You can see the detail of the file ID of spreadsheet at here.
/gviz/tq
gid=###
You can use gid=911257845.
tqx=out:csv
This has to be used instead of output=csv.
tq=### query ###
You can use tq=select%20*%20where%20F%3E300.
Note :
Each number corresponds.
And please share the Spreadsheet as follows. This is difference from "Publish to the web" on Spreadsheet.
On Google Drive
On the Spreadsheet file
right-click -> Share -> Advanced -> Click "change" at "Private - Only you can access"
Check "On Anyone with the link"
Click "Save"
At "Link to share", copy URL.
Retrieve file ID from ``https://docs.google.com/spreadsheets/d/###
I need some help with PHPEXCEL library, everything works great, I'm successfully extracting my SQL query to excel5 file, I need to give this file to transport company in order to auto collect informations about packages, unfotunately the generated excel file has some ascii characters between each letter of the cell text, and when the excel file is imported you need to manually delete these charaters.
If I open the excel file, everything is fine I see: COMPANY NAME, If I open the excel file with notepad++, I see the cell values this way: C(NUL)O(NUL)M(NUL)P(NUL)A(NUL)N(NUL)Y N(NUL)A(NUL)M(NUL)E
If I open again the file with excel and save, then reopen with notepad++ I see COMPANY NAME.
So I do not understan why every time I create an excel file using PHPEXCEL my every letter of all words are filled with (nul) every letter.
So how do I prevent the generated excel file to include (nul) between every word????
Also if you open the original excel file generated from PHPExcel samples are also filled with (nul) and if you open and save it, the (nul) is gone.
Any help would be appreciated, thanks.
what is the (nul) ??? 0x00??? char(0)???
ok, here is the example:
error_reporting(E_ALL);
ini_set('display_errors', TRUE);
ini_set('display_startup_errors', TRUE);
date_default_timezone_set('Europe/London');
if (PHP_SAPI == 'cli')
die('Disponibile solo su browser');
require_once dirname(__FILE__) . '/Classes/PHPExcel.php';
$objPHPExcel = new PHPExcel();
$objPHPExcel->getProperties()->setCreator("Solidus")
->setLastModifiedBy("Solidus")
->setTitle("Import web")
->setSubject("Import File")
->setDescription("n.a")
->setKeywords("n.a")
->setCategory("n.a");
$objPHPExcel->setActiveSheetIndex(0)
->setCellValueExplicit("A1", "COMPANY")
->setCellValue('A2', 'SAMSUNG');
$objPHPExcel->getActiveSheet()->setTitle('DDT');
$objPHPExcel->setActiveSheetIndex(0);
header('Content-Type: application/vnd.ms-excel');
header('Content-Disposition: attachment;filename="TEST.xls"');
header('Cache-Control: max-age=0');
header('Cache-Control: max-age=1');
header('Cache-Control: private',false);
$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');
ob_end_clean();
$objWriter->save('php://output');
As you can see from this little example, this scripts creates a file excel5 with 2 cells, A1 = COMPANY, A2 = SAMSUNG
when I send this file to the transport company, they import the file into their system, but as you can see from the picture, there is an weird character between each letter.
so I noticed every time I open the generated Excel5 with notepad++ file I get:
S(nul)A(nul)M(nul)S(nul)U(nul)N(nul)G
If I save the save with excel and then open it again with notepad++ I get:
SAMSUNG
and this file is ok for the transport company
so my question is, how should I avoid the file generated to contain thi '(nul) charachter between each letter????
some help?
weird characters
SAMSUNG
I found the soluion by myself, I explain just in case anyone has also this problem:
there is not way to change the way the excelfile is encoded by PHPEXCEL
so I figured out the problem was reading the file, I did some simulations and reproduce the problem, every time a read the file and put the result into inputs a get weird characters:
C�O�M�P�A�N�Y�
If I set the output enconding enconding as follows:
$excel->setOutputEncoding('UTF-8');
the file loads fine, so the problem was not creating the excel file, but reading the excel file.
If I print the variable with ECHO I get: "COMPANY",
if I put the variable on input as value I get: "C�O�M�P�A�N�Y�"
setting the output solves the problem, but I would like to know why the difference when I put the variable on input as value, thanks
do you know why some class things changed after upgrading from 3.1 to 6.3 SP2?
For example our Password fields ... The Format property is Class default - correct is Invisible.
Thanks in Advance for any tips!
Did you first save all your files as text ( .apt ), not Binary ( .apl or .app ) .
Best Tip: Don't use the 'Migration Wizard' .
After saving as Text, you should open each file in TD6.3 to do the conversion. Don't double click from File Explorer to open , but open from within TD itself.
Have done many upgrades this way , and never a problem.
Also , are you running on a TD6.3 certified O/S i.e. not Win XP , else unexpected results in conversion. See Compatibility Matrix to be sure: http://www.guptatechnologies.com/Products/App_Dev/TeamDeveloper/TeamDeveloperCompatibilityMatrix.aspx
Being a 50 mB APT implies you have 'Merged' all the apl's first. ? You cant do this and then convert without loosing settings. - You must save each individual .apl ( and any .app's ) as Text ( do not 'Merge' anything ) . To save each apl as Text , 'Save As' --> Select 'save as Type' --> 'Text( *.apt )' --> your file name will revert to xxx.apt before you Save it , so change it at this point to xxx.apl --> Then click Save. This way your .apl will Save as Text , but with a ',apl' prefix . From past experience , converting ( upgrading ) a Merged file will never work .
I am trying to open some website url links with a parameter in my browser. I made a batch file using this code :
#echo off
start "images" "www.images.com/1000/image.jpg"
start "images" "www.images.com/1001/image.jpg"
start "images" "www.images.com/1002/image.jpg"
...
...
start "images" "www.images.com/5000/image.jpg"
All I want is to create a For loop that will do that :
For (i=1000; i<5000 ; i++)
{
start "images" "www.images.com/i/image.jpg"
}
where "i" is a parameter of the website link. I am new in the batch file creation and I cannot figure out how to make it work. I tried this one but it did not work:
for i in {1000..5000}
do
start "images" "www.images.com/$i/image.jpg"
This question is a first step. Then i want to save the images shown on this links, only if the links are valid (not dead like in 403, 404 errors)
For /L %%i in (1000,1,5000) do (
start "images" "www.images.com/%%i/image.jpg"
)
You didn't even try using correct syntax, instead assuming that cmd is like bash. Yay.
What you're looking for can be found with help for:
for /l %%i in (1000,1,5000) do ...
I'm unsure how you even plan to proceed from here, though, as your current approach will not allow you to save images. Also opening 4000 tabs in your browser will likely be not fun either.
You may want to take a look at PowerShell where the whole task you described is trivial:
4000..5000 | % { [IO.File]::WriteAllBytes("H:\$_.png", (iwr www.images.com/$_/image.jpg).Content) }
And even without the need for external programs (e.g. wget or curl).