[web2py] Re: Python 3 - Traceback problems

2019-02-16 Thread Brian M
Looks like if you use the latest git version then the error tickets work as expected. On Friday, February 15, 2019 at 10:04:50 AM UTC-6, Kevin Keller wrote: > > Is there any update to this? > > On Friday, 1 February 2019 17:21:40 UTC+1, Brian M wrote: >> >> So I'm t

[web2py] Python 3 - Traceback problems

2019-02-14 Thread Brian M
Am I really the only one having this problem? Having the error ticket system not work seems like a pretty significant obstacle to using web2py with python 3.7 -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

[web2py] Web2py with python3: difference in error reporting

2019-02-05 Thread Brian M
Reported the same a few days ago but have heard nothing. :( https://groups.google.com/forum/m/#!topic/web2py/dTsDZJ8jhyg -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list

[web2py] Python 3 - Traceback problems

2019-02-01 Thread Brian M
So I'm trying to finally move my web2py apps over to Python 3.7 before Python 2.7 reaches EOL and, while for the most part they're working fine, I am finding that when there is a problem the web2py Error ticket is just about useless (doesn't tell you where the error actually occurs) because

[web2py] Re: Caching DAL Selects - only cache.ram works?

2018-04-26 Thread Brian M
ie Brown 1 Snoopy 2 John Arbuckle 2 Garfield 2 John Arbuckle 3 Odie On Tuesday, April 24, 2018 at 4:44:46 PM UTC-5, Massimo Di Pierro wrote: > > please post a minimal model to reproduce the problem. > > On Tuesday, 3 April 2018 17:15:25 UTC-5, Brian M wrote: >> >> Fur

[web2py] Re: 'Column table.id not found (SQLTABLE)'

2018-04-20 Thread Brian M
Thank you for mentioning this - just wasted an hour plus trying to figure out why my code had stopped working only to find that it was because I'd done pip install pydal for something else and foolishly not used a venv. Uninstalled pydal and everything was good again. So warning to others,

[web2py] Re: Caching DAL Selects - only cache.ram works?

2018-04-06 Thread Brian M
So it caching selects to disk or redis supposed to only work if you have uniquely named fields? It doesn't seem to make a difference if I set cachable=True or not. On Tuesday, April 3, 2018 at 5:15:25 PM UTC-5, Brian M wrote: > > Further investigation shows that cache.redis plays

[web2py] Re: Caching DAL Selects - only cache.ram works?

2018-04-03 Thread Brian M
M UTC-4, Anthony wrote: >> >> It should work. Could be a bug specific to using pyodbc. Have you tried >> it with other databases/drivers? Feel free to file a PyDAL issue. >> >> Anthony >> >> On Tuesday, April 3, 2018 at 12:40:50 PM UTC-4, Brian M wrote: >&g

[web2py] Caching DAL Selects - only cache.ram works?

2018-04-03 Thread Brian M
I've been playing with caching and looking through the mailing list and have a bit of confusion about whether or not you can actually cache DAL Selects with anything other than cache.ram due to issues with what can/cannot be pickled. When I use db(...).select(...,cache=(cache.disk, 300),

[web2py] Re: iterselect() and doing other DB actions - Connection is busy with results for another command

2018-01-10 Thread Brian M
r the next person that might find this. On Wednesday, January 10, 2018 at 3:26:16 PM UTC-6, Anthony wrote: > > On Wednesday, January 10, 2018 at 2:48:34 PM UTC-5, Brian M wrote: >> >> Thank you Anthony, that works! >> >> Only issue is that while using iterselec

[web2py] Re: iterselect() and doing other DB actions - Connection is busy with results for another command

2018-01-10 Thread Brian M
gt; Note, it may need to be all caps -- MARS_CONNECTION. > > Anthony > > On Wednesday, January 10, 2018 at 10:48:19 AM UTC-5, Brian M wrote: >> >> I'm attempting to process through record sets from DAL queries that can >> sometimes return hundreds of thousands of records.

[web2py] iterselect() and doing other DB actions - Connection is busy with results for another command

2018-01-10 Thread Brian M
I'm attempting to process through record sets from DAL queries that can sometimes return hundreds of thousands of records. To try to keep memory usage under control I wanted to use iterselect() instead of a plain DAL select(). However, the problem I'm running into is that as I process each

[web2py] Re: Azure deployment recommendations?

2017-05-25 Thread Brian M
4, 2017 at 7:10:48 PM UTC-7, Brian M wrote: >> >> I'm looking to try deploying a web2py app on Azure. Is the route >> mentioned here >> <https://groups.google.com/forum/#!topic/web2py/XGxM_Tb9nJ4> still the >> best approach? Since running scheduled tasks will b

[web2py] Azure deployment recommendations?

2017-05-24 Thread Brian M
indows service via NSSM) on Azure? Any tips or recommendations would be appreciated. Thanks, Brian M -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You re

[web2py] Re: widget.autocomplet vs IS_IN_DB : formatting, filtering

2017-05-08 Thread Brian M
I've used bootstrap-select ( https://silviomoreto.github.io/bootstrap-select/examples/ ) to enhance standard select drop down lists and allow live searching. Would work well with your lists ofbecause the user can just type in part of any one of them and the options automatically filter

[web2py] Re: web2py behind IIS - 404 File or Directory Not Found.

2017-04-07 Thread Brian M
I cannot truly help, but I do use IIS and have found that it can be cantankerous. I would suggest simply trying to get a static file from web2py then you can work on the IIS settings to allow certain types of files that it might be blocking. The 404 on a new IIS installation simply means you

[web2py] Re: TABLE and TBODY helpers add TR innapropriately

2017-04-07 Thread Brian M
Leonel thanks for your help. I did need to put everything in the XML the way I was doing it because otherwise it all gets escaped. But that is because I was basically converting everything to a string first which is not what I wanted so you were right and I was confused. As far as why not put

[web2py] Re: TABLE and TBODY helpers add TR innapropriately

2017-04-07 Thread Brian M
Anthony, this is what I was looking for. Thanks! I am trying not to build the html myself and use the helpers instead. I am going for readability and ease of use for others to modify later. In all the examples in the book nowhere did it show the append and insert for the HTML helpers I looked

[web2py] TABLE and TBODY helpers add TR innapropriately

2017-04-06 Thread Brian M
I am trying to build a table from a joined set of db tables and need to do quite a bit of processing to make the links and buttons in each row. Making the code readable is important to me so I do not want to put one giant long line of code to do everything and make it impossible for another

[web2py] Re: Autoincrement which resets each month (not primary id)

2017-03-05 Thread Brian M
First of all, at the risk of asking a silly question - is there actually a reason to store this secondary ID in the database rather than just have it calculated on the fly as-needed using a virtual field? Assuming that you've got a created_date field already in the table that'll give you the

[web2py] Re: Difference of two date field in years

2016-12-11 Thread Brian M
Like Anthony said, without seeing your code we can't help. What exactly do you mean by "is not able to recognize date fields as date"? As an alternative to dateutil you could also look into the Pendulum package (https://pendulum.eustace.io/) which makes playing with dates even easier. On

Re: [web2py] Re: Performance using MSSQL stored procedures

2016-12-02 Thread Brian M
https://datatables.net/extensions/scroller/examples/ if you must have huge numbers of rows displayed. On Friday, December 2, 2016 at 2:25:14 PM UTC-6, Dave S wrote: > > On Friday, December 2, 2016 at 12:33:46 AM UTC-8, Gabor Nyul wrote: >> >> Brian, >> >> In fact this is already done. I have a

[web2py] Re: Javascript functions for Canvas not working

2016-12-02 Thread Brian M
In case other have this sort of a problem where javascript events are affected by the css of bootstrap... the problem was in the css file: bootstrap.min.css somehow the relative position causes the event not to bubble up. How jacked up is that?

Re: [web2py] Re: Performance using MSSQL stored procedures

2016-12-01 Thread Brian M
What Dave S. said is key > > "*If you had insight into what the users were looking for during their > examination of the data*, you may be able to provide a better query that > could *simplify the data presentation*." Sit down with your users and find out what it is that they *actually* need

Re: [web2py] Re: https causes site to be in text

2016-12-01 Thread Brian M
The web server block for https probably needs all the same locations and error pages and such as the http server block has for the site to act the same. If those rules created identify the locations of items for the web server allow it to work in http, it only makes sense that the same rules

[web2py] Javascript functions for Canvas not working

2016-11-30 Thread Brian M
I have created a codepen that draws on the canvas and used a javascript addEventListener to capture the mouse clicks. I think that not working properly is my issue. What would be the proper procedure to grab a codepen sample and serve it up in the framework properly? I am still on the learning

Re: [web2py] Re: Performance using MSSQL stored procedures

2016-11-30 Thread Brian M
Can you use web2py for a reporting site - sure, a lot of what I do with it is reporting. I've been using DataTables.net which can provide pagination, sorting, search, aggregation and even basic export (via TableTools) for almost free. While it can enhance regular old HTML tables, with large

[web2py] setup_exe.py bbfreeze- Not building working executable

2016-11-30 Thread Brian M
Has anybody built their own Windows executable using extras\build_web2py\setup_exe.py lately? I've copied setup_exe.py and setup_exe.conf to the web2py TLD and ran python setup_exe.py bbfreeze and it builds the binary alright. But then when I actually launch the executable and fire up web2py

[web2py] Re: Do conditionals short circuit for DAL?

2016-11-26 Thread Brian M
Well even if you're writing the query using the DAL the actual data processing is being done by the database itself so that's where the "short circuiting" would need to happen and is dependent on the database's query optimization. Try running a SQL version of the query directly against the DB

[web2py] Re: Under Scheduler request.is_scheduler is None rather than True - Why?

2016-10-09 Thread Brian M
ue (seems to work > after a quick test on Windows). > > Anthony > > On Monday, October 3, 2016 at 5:46:26 AM UTC-4, Niphlod wrote: >> >> can you please file a bug on https://github.com/web2py/web2py/issues ? >> I'd like to keep track of it and fix ASAP >> >>

[web2py] Re: Scheduler - response.render no longer working

2016-10-09 Thread Brian M
;> I'll open an issue and propose a fix. >> >> Anthony >> >> On Monday, October 3, 2016 at 5:48:40 AM UTC-4, Niphlod wrote: >>> >>> hum. Trunk has been recently updated in the management of caching code >>> for controllers and views wonder if

[web2py] Re: Under Scheduler request.is_scheduler is None rather than True - Why?

2016-10-03 Thread Brian M
https://github.com/web2py/web2py/issues/1484 On Monday, October 3, 2016 at 4:46:26 AM UTC-5, Niphlod wrote: > > can you please file a bug on https://github.com/web2py/web2py/issues ? > I'd like to keep track of it and fix ASAP > > On Monday, October 3, 2016 at 5:45:21 AM UTC+2

[web2py] Under Scheduler request.is_scheduler is None rather than True - Why?

2016-10-02 Thread Brian M
Is there a reason why when something is run under the scheduler request.is_scheduler = None rather than True? When you access request.is_scheduler from outside of the scheduler you get False as one would expect. The current None value seems strange/non-intuitive. #this won't work if

[web2py] Scheduler - response.render no longer working

2016-10-02 Thread Brian M
OK, so I've had multiple scheduled tasks running for years that use response.render('path/to/template.html', dict(var= 'something')) to help build email bodies and it has been working perfectly. Now when I try to upgrade to the latest web2py trunk (was on 2.13.4 - yeah I'm a bit behind) all

[web2py] Re: DAL connection to MSSQL

2016-04-06 Thread Brian M
You can do it but you must tell the DAL that the table exists. It won't just discovered existing tables for itself. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report

[web2py] DAL connection to MSSQL

2016-04-04 Thread Brian M
I think db._tables only lists the tables you have defined within the DAL rather than going to the database itself and listing any tables that are there independent of the DAL (for example if you are connecting to a database that wasn't created through the DAL). Have you defined any tables

Re: [web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-23 Thread Brian M
s coming form > new web2py version or not). > > Or could it be possible that you create the archive table manually back in > time? Or that some file in app/databases/ folder get deleted?? > > Richard > > > > On Tue, Feb 23, 2016 at 11:12 AM, Brian M <bmer...@gma

Re: [web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-23 Thread Brian M
g() for one turn... You try access your app with >> only one table under record versioning to see if it works... Then if this >> work, I would make sure (explicit) what is the name of the archive table to >> see if the issue go away... >> >> Richard >> >> On Mon, F

Re: [web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-22 Thread Brian M
is_active='is_active') > > Where I specified the name of the table to use for archiving records... > > You may have a look at your history table(s) and try to set the previous > parameters for each of your instanciation of the _enable_record_versioning() > > Richa

Re: [web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-22 Thread Brian M
error message? > > On Mon, Feb 22, 2016 at 9:53 PM, Brian M <bmer...@gmail.com > > wrote: > >> The restore was done with MS SQL Server's built-in backup & restore so >> yes it has all of the tables and info. The dozens of other tables in my >> database

Re: [web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-22 Thread Brian M
8:39:22 PM UTC-6, Richard wrote: > > If you restore database like for like, why are you bother with > fake_migrate... Just leave everything to migrate=False should be alright if > you dump contains all the tables... > > Richard > > On Mon, Feb 22, 2016 at 4:55 PM, Brian M &

[web2py] Restored DB, _enable_record_versioning() and fake migrations?

2016-02-22 Thread Brian M
I seem to have run into a problem with tables I'm using _enable_record_versioning() with. I'm setting up on a new computer and have restored a DB backup to the new computer. Now when I try to run pages that utilize those tables the database is complaining that the _archive tables already

[web2py] Re: daily scheduler task - FIX

2016-02-21 Thread Brian M
the times_failed becomes zero and now you're going to calculate incorrect next_run_time values (they'll likely end up in the past) and just end up with your task running extra again. So not quite so simple of a fix as I initially thought. :\ On Sunday, February 21, 2016 at 9:44:41 AM UTC-6, Brian M

[web2py] Re: daily scheduler task - FIX

2016-02-21 Thread Brian M
the times_failed becomes zero and now you're going to calculate incorrect next_run_time values (they'll likely end up in the past) and just end up with your task running extra again. So not quite so simple of a fix as initially On Sunday, February 21, 2016 at 9:44:41 AM UTC-6, Brian M wrote

[web2py] Re: daily scheduler task - FIX

2016-02-21 Thread Brian M
Well I was looking at it as the task was still run by the scheduler even if it didn't complete successfully so the run count should go up regardless. If you are not using the prevent drift option then the scheduler bumps forward the next run time whether or not the task was successful so my

[web2py] Re: daily scheduler task

2016-02-20 Thread Brian M
it. Brian On Saturday, February 20, 2016 at 8:21:24 PM UTC-6, Brian M wrote: > > My setup is on Windows with the scheduler running as a service via nssm. I > have it set to run every 86400 seconds (24hrs) with infinite number of runs > and retries. The timeout is something like 2 or 3

[web2py] Re: daily scheduler task

2016-02-20 Thread Brian M
My setup is on Windows with the scheduler running as a service via nssm. I have it set to run every 86400 seconds (24hrs) with infinite number of runs and retries. The timeout is something like 2 or 3 minutes. I am also using the "cron like" option so that it always runs at exactly the same

[web2py] Re: daily scheduler task

2016-02-19 Thread Brian M
Oddly enough I actually had this happen this past weekend. I have a daily task that sends plant status update emails and the view template that renders the email body was choking because of an unexpected dividide by zero. The first day after the bad data was entered the scheduled run did

[web2py] Re: Select statement with MSSQL

2015-12-19 Thread Brian M
You must first tell the DAL about the tables in your database before you can ask it to select data from them. http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#Table-constructor On Saturday, December 19, 2015 at 3:39:45 AM UTC-6, sa wrote: > > Hi, > > Can not select

[web2py] Re: LOAD and export to CSV

2015-09-29 Thread Brian M
and set a link to > download it as part of the LOAD return, a two step process for the export > scenario. > I was just hoping someone had a better idea. > > Thanks, > Denes > > > > On Monday, September 28, 2015 at 8:38:37 PM UTC-4, Brian M wrote: >> >> Hav

[web2py] LOAD and export to CSV

2015-09-28 Thread Brian M
Have you tried setting the appropriate content type header before returning? I've not done it inside a LOAD before but know that setting the content type will normally get the browser to download & save a CSV file rather than just display it. Brian -- Resources: - http://web2py.com -

[web2py] Re: Bug in XML(...,sanitize=True) ?

2015-06-28 Thread Brian M
. Will fix it today. On Friday, 26 June 2015 18:05:27 UTC-5, Brian M wrote: I'm working on upgrading to the latest web2py version and may have uncovered a bug in the sanitizer. If you use XML(form.var.something, sanitize=True) and form.var.something is just a plain string without any tags

[web2py] Bug in XML(...,sanitize=True) ?

2015-06-26 Thread Brian M
I'm working on upgrading to the latest web2py version and may have uncovered a bug in the sanitizer. If you use XML(form.var.something, sanitize=True) and form.var.something is just a plain string without any tags then what you end up getting returned is an empty string rather than the

[web2py] Re: FYI - MSSQL, Executesql and data columns retrieved as strings

2015-06-18 Thread Brian M
OK so what is the recommended adapter for news versions? I saw that there are like 4 different mssql adapters in the dal source but it wasn't really clear which one to use when. On Wednesday, June 17, 2015 at 1:42:02 AM UTC-5, Niphlod wrote: 10.0 for 2008, 11.0 for 2012, (or 12.0, if sql

[web2py] FYI - MSSQL, Executesql and data columns retrieved as strings

2015-06-16 Thread Brian M
This is just a helpful tip should anyone else run into this problem. When using MS SQL 2012 (may also happen with 2010 and 2008) and the DAL's executesql() feature, if your query includes data type columns they'll have a tendency to be pulled in by pyodbc as unicode strings rather than dates.

[web2py] Anybody Using PTVS (Python Tools for Visual Studio)?

2015-06-07 Thread Brian M
Is anybody developing with PTVS who's got debugging and everything setup and willing to share your config? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues)

[web2py] Re: mod_wsgi error caused (maybe) by css transferred with MIME type text/plain

2015-04-02 Thread Brian M
I think that Weheh may be on to something. I had been using Apache 2.2.22 and just grabbed a fresh copy of 2.2.29 from Apache Lounge https://www.apachelounge.com/download/additional/ and tried it out on my desktop and it appears that static files are now being served directly by Apache rather

[web2py] Re: mod_wsgi error caused (maybe) by css transferred with MIME type text/plain

2015-03-31 Thread Brian M
Mine shows this for a css file HTTP/1.1 200 OK Date: Tue, 31 Mar 2015 21:30:03 GMT Server: Apache/2.2.22 (Win32) mod_wsgi/3.3 Python/2.7.2 Content-Length: 2961 X-Powered-By: web2py Last-Modified: Sat, 15 Mar 2014 03:13:58 GMT Pragma: cache Cache-Control: private X-UA-Compatible: IE=edge

[web2py] Re: mod_wsgi errors -- dead in the water

2015-03-30 Thread Brian M
I also run with the apache + mod_wsgi combo on windows and see this error a lot. Never have been able to figure out a cause other than the client disconnecting like niphlod mentioned. If it is something else that can actually be fixed I'd love to know. Not sure if it matters but I see it

[web2py] Re: Web2py: Create a CSV file to download for an executesql result

2015-03-28 Thread Brian M
Here's an old post with the solution that I use for this https://groups.google.com/d/msg/web2py/4QhEULmJ8YE/aNBcJv81RocJ Yep, I've got a processing app that spits out all sorts of csv files based on data gathered from multiple sources. Here's a little helper function I use def

Re: [web2py] Re: Running multiple lines of SQL in executesql

2015-03-11 Thread Brian M
Strange. Does that same query work if you enter it directly in your DB's interface? I'm guessing from the link you provided that you're using MySQL; I've only done it with MS SQL and SQLite but I'd think that the triple quoting technique should work with other databases too. On Wednesday,

[web2py] Re: Running multiple lines of SQL in executesql

2015-03-10 Thread Brian M
Actually just surround your big long multi line SQL statement with triple quotes and it will work fine. I do that all the time. No need for the \ at each line break then either. You can declare and set your @variables all within one executesql query too. On Tuesday, March 10, 2015 at 2:36:28

[web2py] Re: Web2py, Apache and Ubuntu 14.04

2014-10-07 Thread Brian M
of the misconfiguration of the firewall port 443 was closed. I am not sure whether it's a good idea to make every web2py request an https request. But this should be discussed by the experts. Martin 2014-10-05 23:36 GMT+02:00 Brian M bmer...@gmail.com javascript:: What exactly

[web2py] Re: Web2py, Apache and Ubuntu 14.04

2014-10-05 Thread Brian M
What exactly happens when you try to access your pages? Are you getting 404 responses or something else? Besides checking the apache error logs take a quick look at the access logs to make sure there isn't a bad rewrite rule causing you headaches - I seem to remember that's how I tasked down

[web2py] Re: Accesing table from external database

2014-09-19 Thread Brian M
José, Just because the database was not created by web2py does not automatically mean that you cannot access it through the DAL. As long as the table you want to get at has an auto-increment integer primary key field you can define that table through the DAL - even if the identity field is not

[web2py] Re: Accesing table from external database

2014-09-17 Thread Brian M
What do you mean by external database? Are you actually meaning a legacy database that the DAL didn't create itself? You can certainly connect web2py to such a database through the DAL or even just using db.executesql(). If you need to get a list of valid options for your combobox you can do

[web2py] Re: Web2py Deployment Script for Ubuntu 14.04

2014-07-18 Thread Brian M
I posted about this a couple weeks ago along with what worked for me ,,https://groups.google.com/forum/#!searchin/web2py/Apache$20Ubuntu%7Csort:date/web2py/o6OGQRQTN6Y/oJJQMGChgpcJ On Friday, July 18, 2014 7:14:18 AM UTC-5, Auden RovelleQuartz wrote: This recipe which had worked: { One

[web2py] Re: update database right from view?

2014-07-10 Thread Brian M
Maria, if you really want to you can build the entire form in the view with good old HTML. 1. An example set of sentence, meaning and word forms may be helpful - sounds like you're probably doing some sort of translation thing or maybe it is a quiz? 2. You'll need to add form/form

[web2py] Re: Ubuntu 14.04 Setup Script with Apache - Issues?

2014-06-24 Thread Brian M
to avoid the issues. Thanks On Wednesday, June 18, 2014 11:08:33 PM UTC-4, Brian M wrote: Anybody else tried setting things up on Ubuntu 14.04 using scripts/setup-web2py-ubuntu.sh? I tried it this evening and ran into multiple issues 1) The generated sites-available/default configuration

[web2py] Re: Trying to use the LOAD helper, if a button is clicked

2014-06-23 Thread Brian M
Looks like the new datatables.net v1.10 has a new API so there are now probably better ways to do this than I showed. On Monday, June 23, 2014 4:51:53 AM UTC-5, Tomeu Roig wrote: Thanks Brian El lunes, 23 de junio de 2014 03:56:32 UTC+2, Brian M escribió: Tomeu, At the moment I'm just

[web2py] Re: Trying to use the LOAD helper, if a button is clicked

2014-06-22 Thread Brian M
Tomeu, At the moment I'm just letting datatables.net enhance a plain html table for me. One of these days I'll probably get around to giving it a json datasource but so far it hasn't been a priority for my usage. As a bonus, here's some of how to update the datatables.net display after using

[web2py] Re: Ubuntu 14.04 Setup Script with Apache - Issues?

2014-06-20 Thread Brian M
might need addressing. Brian On Wednesday, June 18, 2014 10:08:33 PM UTC-5, Brian M wrote: Anybody else tried setting things up on Ubuntu 14.04 using scripts/setup-web2py-ubuntu.sh? I tried it this evening and ran into multiple issues 1) The generated sites-available/default configuration

[web2py] Re: CSS and graphics not loading in admin interface (lighttpd)

2014-06-19 Thread Brian M
It may be that response.static_version is enabled but the web server is not setup to handle the resulting URL. Try using your browser's developer tools to see what the URL for the missing files is; if it includes /static/_#.#/some/file.CSS this is your problem. See the deployment section of

[web2py] Ubuntu 14.04 Setup Script with Apache - Issues?

2014-06-18 Thread Brian M
Anybody else tried setting things up on Ubuntu 14.04 using scripts/setup-web2py-ubuntu.sh? I tried it this evening and ran into multiple issues 1) The generated sites-available/default configuration file must be linked to sites-enabled/default.conf or else it doesn't actually get used and all

[web2py] Re: Trying to use the LOAD helper, if a button is clicked

2014-06-18 Thread Brian M
Here's how I'm doing it in an app. I'm not using grid or smartgrid but rather a datatables.net table where each row has a linked edit button. There may be other (better?) ways to do it but this works for me. Each record includes: td{{=A(edit_icon, _href=URL(r=request,f='edit_item',

Re: [web2py] Custom Auth

2014-05-27 Thread Brian M
Greg, I know this is an old thread, but did you ever come up with a solution? I've got an asp.Net app that I'd be nice to be able to authenticate against. Thanks Brian On Wednesday, October 9, 2013 9:22:07 PM UTC-5, GregD wrote: We have to use tables from sql server (aspnet_user and

Re: [web2py] web2py conference - online talks

2014-05-15 Thread Brian M
Massimo, any chance of you posting a tutorial/how to of your setup? :) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because

[web2py] Re: Sending Emails HTMLemails with CSS

2014-05-07 Thread Brian M
Was actually looking at this today and there are a couple of CSS Inliners written in Python that could perhaps be integrated in your workflow. Haven't tried them yet but here are two. http://pythonhosted.org/pynliner/ https://pypi.python.org/pypi/premailer/ On Tuesday, May 6, 2014 2:35:18 PM

[web2py] Re: query DAL

2014-05-01 Thread Brian M
The database view trick would work. Or how about adding a current flag and whenever you do a situation update/insert you set the new record's current flag to true and those of all that person's other situation records to false. You could either do it in web2py or with a database trigger. Seems

[web2py] query DAL

2014-04-28 Thread Brian M
Are you sure that your situation table doesn't have some more fields? Fernando has three entries in situation so how do you know which one is the last one? Are you just going to assume that the highest situation.id is the last one or is there a timestamp in there or some sort of active flag?

[web2py] great news: Sphinx Documentation

2014-04-13 Thread Brian M
Great job niphlod! -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups

[web2py] Best approach to using the DAL with external data sources that will go into multiple tables?

2014-04-08 Thread Brian M
Assuming each source needs the same data fields, how about just using one table and including an extra field to specify which source each record came from? Or if you really want a separate table for each timeseries, you could look into using table inheritance.

[web2py] Re: Can I query muliitple legacy databases?

2014-03-25 Thread Brian M
Please be sure to read the DAL section of the online web2py book it will explain a lot of this. When you use executesql you can choose how to see the results the as_dict means you can address fields/columns as dict keys or you can also use the fields colnames options to get objects just like

[web2py] Can I query muliitple legacy databases?

2014-03-20 Thread Brian M
It works great. I've got reporting sites at work that pull from several different databases using a mix of DAL queries and executesql. Just use the DAL to make the connections to the databases and then query it whichever way best fits your needs! -- Resources: - http://web2py.com -

[web2py] Re: Can I query muliitple legacy databases?

2014-03-20 Thread Brian M
Setup a connection to each of your databases as shown above - then db1 will represent the connection to the first database, db2 the second and so on - or you can just as easily name the database connections db_customer, db_purchases, db_relatives and so on so the names are a bit more

[web2py] Scheduler repeat time drift

2014-01-08 Thread Brian M
Is there any way to keep the time at which recurring tasks run from drifting? I've got several daily tasks that over time go from running at say 10am to 10:30am - it seems like each consecutive run is 20 seconds or so behind the previous day's. Is this simply a matter of the next execution

[web2py] Re: Scheduler repeat time drift

2014-01-08 Thread Brian M
of the first round to the START time of the next cycle)* On Wednesday, January 8, 2014 5:10:38 PM UTC+1, Brian M wrote: Is there any way to keep the time at which recurring tasks run from drifting? I've got several daily tasks that over time go from running at say 10am to 10:30am

[web2py] Re: forgot password not working anymore

2013-12-23 Thread Brian M
I recently experienced something like this as well. Are you trying to do the reset from localhost or remotely? When I experienced this I found that oddly while the forgotten password form would not work when connecting to localhost, if I connected from another computer it worked fine. From

[web2py] Re: LOAD only gives Loading... after upgrade

2013-12-18 Thread Brian M
Anybody have any ideas? This setup worked under older versions of web2py but not anymore - I assume something with the changes to web2py.js but don't know where. On Tuesday, December 17, 2013 11:26:19 AM UTC-6, Brian M wrote: OK, I've got a simple app that shows the behavior: controllers

Re: [web2py] Re: LOAD only gives Loading... after upgrade

2013-12-17 Thread Brian M
, 2013 6:26:14 AM UTC-6, Brian M wrote: Thanks Massimo I will give that a try. Was using firebug last night but wasn't seeing any errors or anything. On Dec 17, 2013 12:53 AM, Massimo Di Pierro massimo.dipie...@gmail.com wrote: Try check with the google chrome js console. It should tell you

[web2py] Re: LOAD only gives Loading... after upgrade

2013-12-17 Thread Brian M
my javascript ajax() call so that it does NOT include an ':eval' argument at the end fixed that. On Tuesday, December 17, 2013 8:09:12 AM UTC-6, Anthony wrote: We probably need to see some code. On Tuesday, December 17, 2013 12:44:23 AM UTC-5, Brian M wrote: This would seem to be the same

[web2py] LOAD only gives Loading... after upgrade

2013-12-16 Thread Brian M
This would seem to be the same issue as https://groups.google.com/d/topic/web2py/kyEYmfQs6L0/discussion but yet the solution offered there (make sure you've got the latest web2py.js) doesn't seem to be working for me. Oddly, I've got another form being loaded with LOAD(ajax=True) on the same

[web2py] Re: Strange Issue with Executesql

2013-11-27 Thread Brian M
instead of just using the DAL with db(db.table.id 0).select() - I'm giving the benefit of the doubt that it must actually be more complex. On Wednesday, November 27, 2013 1:28:53 PM UTC-6, Niphlod wrote: On Wednesday, November 27, 2013 6:48:50 AM UTC+1, Brian M wrote: Querying out 47K rows

[web2py] Re: Cron job every 30 seconds

2013-11-27 Thread Brian M
web2py's scheduler will let you set the repeat period in seconds so you could probably do 30 seconds that way. On Tuesday, November 26, 2013 2:55:16 PM UTC-6, melmg wrote: Is is possible to set up a cron job to run every 30 seconds instead of a minute? I have a function that does an HTTP GET

[web2py] Re: Strange Issue with Executesql

2013-11-26 Thread Brian M
Querying out 47K rows is taking 4.5-5.5 seconds on my laptop (and its specs are nothing special). Not sure how the complexity of my query compares to yours but 20-150 seconds seems slow. Heck I can get back over 800K rows in about 75 seconds. BTW, running the same queries in SQL Server

[web2py] Re: Strange Issue with Executesql

2013-11-19 Thread Brian M
Wow, you actually need to pull 50,000 rows at a time?! Are you sure there isn't some sort of aggregating that couldn't be done at the database level to cut that down? While I work with large tables I have not been retrieving anywhere near that many rows at once. I will give it a shoot and see

[web2py] Re: Strange Issue with Executesql

2013-11-19 Thread Brian M
under certain conditions. (Yeah been there, done that, wasn't much fun) On Tuesday, November 19, 2013 4:43:14 PM UTC-6, Brian M wrote: Wow, you actually need to pull 50,000 rows at a time?! Are you sure there isn't some sort of aggregating that couldn't be done at the database level to cut

[web2py] Re: Strange Issue with Executesql

2013-11-18 Thread Brian M
I was meaning use the SQL server activity monitor to find out exactly what query is being run and how long it is taking. But if you are using SQL server express you won't have that. You can use something like express profile 2.0 which is free though. Being able to see exactly what query is

[web2py] Re: Strange Issue with Executesql

2013-11-16 Thread Brian M
I use executesql with large tables (multiple 100K rows) and have had no such problems. Are your queries really just select * from table or is there more complicated parameters involved? If it can be reliably reproduced them why not use a monitor to watch what sqlserver is actual doing when it

Re: [web2py] Re: web2py scheduler not working

2013-10-24 Thread Brian M
@ranjith, I think that you may be confusing the difference between Unix/Linux cron https://en.wikipedia.org/wiki/Cron and the cronhttp://web2py.com/books/default/chapter/29/04/the-core?search=cron#Cron provided by web2py which are two different things. What @Marin is meaning is that you'd

  1   2   3   4   >