Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB SQL » View Thread |
Messages 1 to 10 of 22 total |
Export from View: Where clause not respected? |
Fri, Oct 9 2009 11:06 AM | Permanent Link |
"Malcolm" | Using 2.03 b4 (u) on D2009
I am trying to export a subset of a table's records. It seemed I would have to use a view in order to limit the records .. but I must be doing it wrong. This test script, run in the Manager, results in *all* records in "Events" being exported: SCRIPT () BEGIN EXECUTE IMMEDIATE 'CREATE VIEW "LiveEvents" AS SELECT * FROM "Events" WHERE "MeetRef"=1'; EXECUTE IMMEDIATE 'EXPORT TABLE "LiveEvents" TO "Events.txt" IN STORE "DRBackup"'; EXECUTE IMMEDIATE 'DROP VIEW "LiveEvents"'; END I was expecting only matching records. This query selects the expected records: SELECT * FROM "Events" WHERE "MeetRef"=1 -- |
Fri, Oct 9 2009 11:53 AM | Permanent Link |
Uli Becker | Malcolm,
> I am trying to export a subset of a table's records. > It seemed I would have to use a view in order to limit the records .. > but I must be doing it wrong. > > This test script, run in the Manager, results in *all* records in > "Events" being exported: I tried the same here with the same result. Seems to be a bug. Regards Uli |
Fri, Oct 9 2009 12:32 PM | Permanent Link |
"Malcolm" | Thanks Uli .. it did look very suspicious.
What are my chances that while Tim is fixing it he will add an encoding parameter to the EXPORT so that I can get it dumped in Utf8? <gdr> |
Fri, Oct 9 2009 1:48 PM | Permanent Link |
"Malcolm" | Malcolm wrote:
> Thanks Uli .. it did look very suspicious. > > What are my chances that while Tim is fixing it he will add an > encoding parameter to the EXPORT so that I can get it dumped in > Utf8? <gdr> Tim While I'm at it, is there a problem with the QUOTE CHAR? If I omit this I get the expected "surrounding all strings". But I need to load this data into MySQL and it does not do quoting of string fields (though it does allow *all* fields to be quoted) so I tried to specify an empty string for the QUOTE CHAR .. and got an error about a 'missing' character. So I tried specifying #0 as the char .. and that seems to surround every field with the #0. Or it looks like it (I may be wrong). So, whatever you find about the QUOTE CHAR, can I ask for the option to have *no* string quoting .. please, please? This is not urgent for me. -- |
Fri, Oct 9 2009 4:01 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Malcolm,
<< I am trying to export a subset of a table's records. It seemed I would have to use a view in order to limit the records .. but I must be doing it wrong. This test script, run in the Manager, results in *all* records in "Events" being exported: >> Hmm, this is a tough one. The problem is with updateable (sensitive) views, and I'm going to have to really look into this one. The problem is that the export occurs at the base table level, underneath the cursor level where the filters are applied for updateable views, and I'm not sure if I can reconcile the two. You may need to take an extra step to dump the results into a temporary table and then export it. -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Oct 9 2009 4:02 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Malcolm,
<< While I'm at it, is there a problem with the QUOTE CHAR? If I omit this I get the expected "surrounding all strings". But I need to load this data into MySQL and it does not do quoting of string fields (though it does allow *all* fields to be quoted) so I tried to specify an empty string for the QUOTE CHAR .. and got an error about a 'missing' character. So I tried specifying #0 as the char .. and that seems to surround every field with the #0. Or it looks like it (I may be wrong). So, whatever you find about the QUOTE CHAR, can I ask for the option to have *no* string quoting .. please, please? >> I'll see what I can do. It seems reasonable to allow the NULL (#0) as the designator for "no quote character". -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Oct 9 2009 4:02 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Malcolm,
<< What are my chances that while Tim is fixing it he will add an encoding parameter to the EXPORT so that I can get it dumped in Utf8? >> We'll be adding some additional import/export options shortly, and I'll see about adding this. -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Oct 9 2009 4:03 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Malcolm,
BTW, to create such a temporary table, just use a: CREATE TEMPORARY TABLE AS SELECT....FROM MyView statement. -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Oct 9 2009 4:34 PM | Permanent Link |
"Malcolm" | Tim Young [Elevate Software] wrote:
> > > I'll see what I can do. It seems reasonable to allow the NULL > (#0) as the designator for "no quote character". Just anything that works to disable string quoting. -- |
Fri, Oct 9 2009 4:36 PM | Permanent Link |
"Malcolm" | Tim Young [Elevate Software] wrote:
> Malcolm, > > BTW, to create such a temporary table, just use a: > > CREATE TEMPORARY TABLE AS SELECT....FROM MyView > > statement. So I may as well just do it from the table and skip the view. -- |
Page 1 of 3 | Next Page » | |
Jump to Page: 1 2 3 |
This web page was last updated on Tuesday, September 17, 2024 at 04:19 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |