[Lift] Re: How can i update and insert record into database via Raw sql in Lift?

2009-12-19 Thread Marcin Jurczuk
not familiar with it,    Thanks very much!    :) Cheers,   Neil On Dec 18, 11:13 pm, Marcin Jurczuk mjurc...@gmail.com wrote: Hi, You have few options: - DB.runQuery(UPDATE blogs set click_counts=click_counts+1 WHERE id=1) - DBprepareStatement(UPDATE blogs set click_counts

[Lift] Re: How can i update and insert record into database via Raw sql in Lift?

2009-12-18 Thread Marcin Jurczuk
Hi, You have few options: - DB.runQuery(UPDATE blogs set click_counts=click_counts+1 WHERE id=1) - DBprepareStatement(UPDATE blogs set click_counts=click_counts+1 WHERE id=?,yourDBConnection) { stmt = stmt.setLong(1,1) stmt.executeUpdate() } Where first 1 in setLong is position in prepared

[Lift] Building war for production mode.

2009-11-27 Thread Marcin Jurczuk
Hello, I'm trying to first test deploy of my app :) I created package (mvn package), uploaded created war as root.war in webapp folder of jetty server and when running app it looks that lift app is running in development mode (no 404 is showed but: The requested page was not defined in your

[Lift] Re: Lift and LDAP

2009-11-27 Thread Marcin Jurczuk
That is amazing :) Probably I will need to bind to AD in near future, so this module is like fallen from heavens :) On 27 Lis, 15:11, TylerWeir tyler.w...@gmail.com wrote: http://jgoday.wordpress.com/2009/11/27/lift-ldap/ One of the requisites to start using Lift at my work, was to use LDAP

[Lift] Access do Database objects from scala:console

2009-11-26 Thread Marcin Jurczuk
Hello, Can someone point me how to access data from Box object return by mapper query: Here is example (mvn scala:console) scala new bootstrap.liftweb.Boot().boot scala import pl.com.company.model._ import pl.com.company.model._ scala import _root_.net.liftweb.mapper._ import

[Lift] Re: Access do Database objects from scala:console

2009-11-26 Thread Marcin Jurczuk
: java.lang.String = image/jpeg scala That is OK - contentType exists .. I tried .toString but doesn't work either .. Best regards, On 26 Lis, 11:52, Jeppe Nejsum Madsen je...@ingolfs.dk wrote: Marcin Jurczuk mjurc...@gmail.com writes: Hello, Can someone point me how to access data from Box object

[Lift] Re: Access do Database objects from scala:console

2009-11-26 Thread Marcin Jurczuk
Nejsum Madsen je...@ingolfs.dk wrote: Marcin Jurczuk mjurc...@gmail.com writes: Thanks .. read that ...and look and dmap implementation however it doesn't work like I expected: scala r.dmap(application/octet-stream)(_.contentType.is) res49: java.lang.String = null This is (probably

[Lift] Maper SQL stored procedures

2009-11-19 Thread Marcin Jurczuk
Hi group, Is there a way for nice support for stored procedures in Mapper Framework. Let assume that I have database where only way to get data is stored procedure for example Instead SELECT * from user I must execute exec dbo.GET_USERS How connect Mapper fields with access to them by stored

[Lift] Re: Maper SQL stored procedures

2009-11-19 Thread Marcin Jurczuk
with stored procedures. If you (or someone else) has a nice abstraction of stored procedures that's type safe, let's see if we can add it to Lift. Thanks, David On Thu, Nov 19, 2009 at 3:23 AM, Marcin Jurczuk mjurc...@gmail.com wrote: Hi group, Is there a way for nice support

[Lift] Re: mvn jetty:run silent error

2009-11-17 Thread Marcin Jurczuk
Today everything is OK. Weird ...maybe moon phase was wrong yesterday : ) On 16 Lis, 18:39, Marcin Jurczuk mjurc...@gmail.com wrote: I dont' have any of variables mentioned by you (MAVEN_OPTS,JAVA_OPTS) Spaces in Windows paths are typical and for last 2 moths since I dig in lift

[Lift] mvn jetty:run silent error

2009-11-16 Thread Marcin Jurczuk
Hi group, I have weird problem with my lab-lift app. Since yesterday I can't bring up jetty up and running. There is no errro just after execute mvn jetty:run I'm getting prompt from cli after few seconds. Here is output from jety:run ===

[Lift] Re: mvn jetty:run silent error

2009-11-16 Thread Marcin Jurczuk
% On 16 Lis, 18:10, David Pollak feeder.of.the.be...@gmail.com wrote: I'm just guessing here... but it looks like the spaces in path names is causing confusion. What are your environment variables? On Mon, Nov 16, 2009 at 8:59 AM, Marcin Jurczuk mjurc...@gmail.com wrote: Hi group

[Lift] External usage of lift ORM

2009-11-02 Thread Marcin Jurczuk
Hello, I would like to use lift ORM(Mapper) without lift, as a part of small cli app. I assume that it is possible but question is how to init MetaMapper/ Mapper class/objects without Boot.scala and DB setup inside it ? Best regards, --~--~-~--~~~---~--~~ You

[Lift] SQL query logging

2009-10-14 Thread Marcin Jurczuk
Hello, I'm trying to dump SQL queries because I have weird error when using SQLServer (syntax error near 'LIMIT') using following code in Boot.scala DB.addLogFunc { case (query, time) = { Log.info(Total queries took + time + ms: ) //query.allEntries.foreach(q

[Lift] Re: Legacy database and column name with spaces

2009-09-10 Thread Marcin Jurczuk
.  What's the SQL syntax for accessing tables/ columns that have spaces in their names?  I can update Mapper to do   the right thing. On Wed, Sep 9, 2009 at 5:34 AM, Marcin Jurczuk mjurc...@gmail.com   wrote: One solution I found is to create object with name without spaces and override

[Lift] Re: CRUDifier and auto menu generation

2009-09-10 Thread Marcin Jurczuk
than one.. On Sep 10, 12:17 pm, Marcin Jurczuk mjurc...@gmail.com wrote: Hello, I'm trying to setup basic CRUD and I almost did it. Problem is when creating menus: Here is Menu builder in Boot.conf Menu(Loc(home, List(index), Home)) :: User.sitemap :: MyModelWithCRUD.menus If I remove one

[Lift] Re: Legacy database and column name with spaces

2009-09-10 Thread Marcin Jurczuk
Good to hear though that you're moving to sane column names :-) -Ross This app have long story - it was born as MS Access DB (that's why weird column names), then it was migrated to SQL server... I could post lots of stories to thedailywtf about meetings with guys from MS Access :)

[Lift] Re: Legacy database and column name with spaces

2009-09-09 Thread Marcin Jurczuk
One solution I found is to create object with name without spaces and override dbColumnName. I don't know however (right now I don't have access to DB) does db driver will handle such column names.. On Sep 9, 10:23 am, Marcin Jurczuk mjurc...@gmail.com wrote: Hello everybody, I have strange