Thanks Graeme, We actually do our updating through views so the truncate table options was not working either. I added a 'delete from <table>' in the BEGIN_SQL and that solved two problems. The data is now deleted and if the table doesn't exist the script stops. I also disabled the creation of the spatial index with your suggestions (it was trying to create a spatial index on the view which it shouldn't).
So thank you for your response. Thanks Gunter --- In [email protected], Graeme Hiebert <[EMAIL PROTECTED]> wrote: > > On 05 Jul 2007, at 10:48 PM, gunter_nt wrote: > > Is there a argument/ MACRO I can pass to the oracle writer to get > > it to fail if the table does not exist? > > Basically, if the table exists, upload the data. If the table does > > not exist, fail or at least output a warning message. > > > Not directly. Assuming you are using one of the "ORACLE8I" table > types, you could always add a benign "BEGIN_SQL{0}" directive for the > dataset being written, which does nothing when the table exists but > fail if it does not exist. Perhaps something like > > > ORACLE8I_BEGIN_SQL{0} "SELECT COUNT(*) FROM MYTABLE" > > > Also.. if the table does exist, is there a way to stop it > > attempting to create indexes? > > > That one's a bit easier. If we're talking about spatial indexes, > just place the fake attribute "oracle_create_indices" onto the DEF > line with a value of "no". For example: > > ORACLE8I_DEF MYTABLE \ > > ID INT \ > > oracle_create_indices no > > HTH, > > -g > For insights into what's up at Safe Software and what's on the development horizon, visit Safe's blog at spatial-etl.blogspot.com. Love FME? Then open your diary to March 6-7, 2008 and write this... "Second Worldwide FME User Conference - Must Attend!" See http://www.safe.com/company/fmeuc2008/index.php for more details. Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/fme/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/fme/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
