[Zope] Why oh why won't my Gadfly Fly ?
John Platten
jplatten@rochester.rr.com
Sun, 26 Dec 1999 12:14:38 -0500
--------------73BA8F056747A8C71C6A8371
Content-Type: text/plain; charset=us-ascii; x-mac-type="54455854"; x-mac-creator="4D4F5353"
Content-Transfer-Encoding: 7bit
Michel,
Here is some more testing that I have done which still leads me to think that
something is wrong here:
http://www.jamenterprises.com:8080
********************
This is the code behind the link "folder_gadfly":
********************
<dtml-var standard_html_header>
<h2><dtml-var title_or_id></h2>
<p>This is the <dtml-var id> Document.</p>
<!--#call "manage_addFolder('Sample')"-->
<!--#call "Sample.manage_addZGadflyConnection('zopadelic', '', 'demo', 'YES',
REQUEST)"-->
<!--#call "Sample.manage_addZSQLMethod('create_table', '1', 'zopadelic', '2',
'create table zopista(col_a integer,col_b integer)')"-->
<!--#call "Sample.create_table.manage_test(REQUEST)"-->
<!--#call "Sample.manage_addZSQLMethod('insert_data', '', 'zopadelic', '',
'insert into zopista (col_a, col_b) values (120, 380)')"-->
<!--#call "Sample.insert_data.manage_test(REQUEST)"-->
<!--#call "Sample.manage_addZSQLMethod('view_data', '', 'zopadelic', '', 'selct
col_a, col_b from zopista')"-->
<p>The Resulting Data is:</p>
<ol>
<!--#with Sample-->
<!--#in view_data-->
<li>col_a is <!--#var col_a-->, col_b is <!--#var col_b-->.</li>
<!--#/in-->
<!--#/with-->
</ol>
<dtml-var standard_html_footer>
********************
And Here are the Results:
********************
Zope Error
Zope has encountered an error while publishing this resource.
Error Type: AttributeError
Error Value: manage_addZSQLMethod
Troubleshooting Suggestions
The URL may be incorrect.
The parameters passed to this resource may be incorrect.
A resource that this resource relies on may be encountering
an error.
For more detailed information about the error, please refer to the
HTML source for this page.
If the error persists please contact the site maintainer. Thank
you for your patience.
Traceback (innermost last):
File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py, line 214,
in publish_module
File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py, line 179,
in publish
File /web1/home1/www/w085036/zope/lib/python/Zope/__init__.py, line 202, in
zpublisher_exception_hook
(Object: ElementWithAttributes)
File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py, line 165,
in publish
File /web1/home1/www/w085036/zope/lib/python/ZPublisher/mapply.py, line 160, in
mapply
(Object: index_html)
File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py, line 102,
in call_object
(Object: index_html)
File /web1/home1/www/w085036/zope/lib/python/OFS/DTMLDocument.py, line 166, in
__call__
(Object: index_html)
File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_String.py,
line 502, in __call__
(Object: index_html)
File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_Util.py, line
335, in eval
(Object: Sample.manage_addZSQLMethod('create_table', '1', 'zopadelic', '2',
'create table zopista(col_a integer,col_b integer)'))
(Info: Sample)
File <string>, line 0, in ?
File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_Util.py, line
127, in careful_getattr
AttributeError: (see above)
Michel Pelletier wrote:
> Please continue to CC the list.
>
> John Platten wrote:
> >
> >
> > Maybe I just don't understand how exactly "gadfly" is supposed to work,
> > but here is the following notes about what I see with "gadfly":
> >
> > 1. Adding new directories to ./zope/var/gadfly will make new database names
> > (ie. directory names) show up in the pick list for selecting which database
> > to establish a new database connection with, however, when I try to "test"
> > the database connection with the "test-tab" by sumitting SQL to the database
> > connection, yes I do get tracebacks such as the following:
> >
> > Zope Error
> >
> > Zope has encountered an error while publishing this resource.
> >
> > Error Type: NameError
> > Error Value: 'LIKES' no such relation in DB
>
> I'm no gadfly expert, but it soulds like your gadfly is running fine.
> You just don't have the table 'LIKES' in whatever db you're connecting
> to. Try using a "create table" type SQL statement. For more info on
> creating tables, see the gadfly docs.
>
> -Michel
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )
--------------73BA8F056747A8C71C6A8371
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Michel,
<p>Here is some more testing that I have done which still leads me to think
that something is wrong here:
<p> <a href="http://www.jamenterprises.com:8080/manage">http://www.jamenterprises.com:8080</a>
<p>********************
<br>This is the code behind the link "folder_gadfly":
<br>********************
<p><dtml-var standard_html_header>
<p><h2><dtml-var title_or_id></h2>
<p><p>This is the <dtml-var id> Document.</p>
<p><!--#call "manage_addFolder('Sample')"-->
<p><!--#call "Sample.manage_addZGadflyConnection('zopadelic', '', 'demo',
'YES', REQUEST)"-->
<p><!--#call "Sample.manage_addZSQLMethod('create_table', '1', 'zopadelic',
'2', 'create table zopista(col_a integer,col_b integer)')"-->
<p><!--#call "Sample.create_table.manage_test(REQUEST)"-->
<p><!--#call "Sample.manage_addZSQLMethod('insert_data', '', 'zopadelic',
'', 'insert into zopista (col_a, col_b) values (120, 380)')"-->
<p><!--#call "Sample.insert_data.manage_test(REQUEST)"-->
<p><!--#call "Sample.manage_addZSQLMethod('view_data', '', 'zopadelic',
'', 'selct col_a, col_b from zopista')"-->
<p><p>The Resulting Data is:</p>
<p><ol>
<br><!--#with Sample-->
<br> <!--#in view_data-->
<br> <li>col_a is <!--#var col_a-->, col_b is <!--#var col_b-->.</li>
<br> <!--#/in-->
<br><!--#/with-->
<br></ol>
<br>
<br><dtml-var standard_html_footer>
<p>********************
<br>And Here are the Results:
<br>********************
<br>
Zope Error
<p>
Zope has encountered an error while publishing this resource.
<p>
Error Type: AttributeError
<br>
Error Value: manage_addZSQLMethod
<br>
<br>
<p>
Troubleshooting Suggestions
<p>
The URL may be incorrect.
<br>
The parameters passed to this resource may be incorrect.
<br>
A resource that this resource relies on may be encountering an error.
<p>
For more detailed information about the error, please refer to the HTML
source for this page.
<p>
If the error persists please contact the site maintainer. Thank you for
your patience.
<br>
<br>
<br>
<p>Traceback (innermost last):
<br> File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py,
line 214, in publish_module
<br> File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py,
line 179, in publish
<br> File /web1/home1/www/w085036/zope/lib/python/Zope/__init__.py,
line 202, in zpublisher_exception_hook
<br> (Object: ElementWithAttributes)
<br> File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py,
line 165, in publish
<br> File /web1/home1/www/w085036/zope/lib/python/ZPublisher/mapply.py,
line 160, in mapply
<br> (Object: index_html)
<br> File /web1/home1/www/w085036/zope/lib/python/ZPublisher/Publish.py,
line 102, in call_object
<br> (Object: index_html)
<br> File /web1/home1/www/w085036/zope/lib/python/OFS/DTMLDocument.py,
line 166, in __call__
<br> (Object: index_html)
<br> File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_String.py,
line 502, in __call__
<br> (Object: index_html)
<br> File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_Util.py,
line 335, in eval
<br> (Object: Sample.manage_addZSQLMethod('create_table',
'1', 'zopadelic', '2', 'create table zopista(col_a integer,col_b integer)'))
<br> (Info: Sample)
<br> File <string>, line 0, in ?
<br> File /web1/home1/www/w085036/zope/lib/python/DocumentTemplate/DT_Util.py,
line 127, in careful_getattr
<br>AttributeError: (see above)
<br>
<br>
<p>Michel Pelletier wrote:
<blockquote TYPE=CITE>Please continue to CC the list.
<p>John Platten wrote:
<br>>
<br>>
<br>> Maybe I just don't understand how exactly "gadfly" is supposed to
work,
<br>> but here is the following notes about what I see with "gadfly":
<br>>
<br>> 1. Adding new directories to ./zope/var/gadfly will make new database
names
<br>> (ie. directory names) show up in the pick list for selecting which
database
<br>> to establish a new database connection with, however, when I try
to "test"
<br>> the database connection with the "test-tab" by sumitting SQL to the
database
<br>> connection, yes I do get tracebacks such as the following:
<br>>
<br>>
Zope Error
<br>>
<br>>
Zope has encountered an error while publishing this resource.
<br>>
<br>>
Error Type: NameError
<br>>
Error Value: 'LIKES' no such relation in DB
<p>I'm no gadfly expert, but it soulds like your gadfly is running fine.
<br>You just don't have the table 'LIKES' in whatever db you're connecting
<br>to. Try using a "create table" type SQL statement. For
more info on
<br>creating tables, see the gadfly docs.
<p>-Michel
<p>_______________________________________________
<br>Zope maillist - Zope@zope.org
<br><a href="http://lists.zope.org/mailman/listinfo/zope">http://lists.zope.org/mailman/listinfo/zope</a>
<br>** No cross posts or HTML encoding! **
<br>(Related lists -
<br> <a href="http://lists.zope.org/mailman/listinfo/zope-announce">http://lists.zope.org/mailman/listinfo/zope-announce</a>
<br> <a href="http://lists.zope.org/mailman/listinfo/zope-dev">http://lists.zope.org/mailman/listinfo/zope-dev</a>
)</blockquote>
</html>
--------------73BA8F056747A8C71C6A8371--