Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8838941
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T10:07:30+00:00 2026-06-14T10:07:30+00:00

I just started learning Grails and I’m trying to play around with the database

  • 0

I just started learning Grails and I’m trying to play around with the database using the grails console, but I notice that there’s a difference between running grails console and running grails, then console:

When launching grails console straight from Terminal:

~/Desktop/Grails-lab/racetrack $ grails console
| Compiling 1 source files.....

In the console:

groovy> import racetrack.* 
groovy> def z = new User(userName:"bangkuangwang",fullName:"noge noge",website:"noge.com",email:"email@email.com",bio:"hello world",password:"123123") 
groovy> z.save() 
groovy> println(z.errors) 
groovy> User.count 

grails.validation.ValidationErrors: 0 errors

Result: 1

When launching using grails, then console:

~/Desktop/Grails-lab/racetrack $ grails
| Enter a script name to run. Use TAB for completion: 
grails> console
| Compiling 1 source files.....

In the console:

groovy> import racetrack.* 
groovy> def z = new User(userName:"bangkuangwang",fullName:"noge noge",website:"noge.com",email:"email@email.com",bio:"hello world",password:"123123") 
groovy> z.save() 
groovy> println(z.errors) 
groovy> User.count 

Exception thrown

groovy.lang.MissingMethodException: No signature of method: racetrack.User.save() is applicable for argument types: () values: []
Possible solutions: save(), save(boolean), save(java.util.Map), wait(), last(), any()
at com.springsource.loaded.ri.ReflectiveInterceptor.jlrConstructorNewInstance(ReflectiveInterceptor.java:963)
at racetrack.User.save(User.groovy)
at racetrack.User$save.call(Unknown Source)
at ConsoleScript0.run(ConsoleScript0:3)
at com.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1231)
at com.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1231)

Can anyone explain to me why are the 2 methods of launching grails console behave differently?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T10:07:31+00:00Added an answer on June 14, 2026 at 10:07 am

    Looks like a bug.
    I would recommend you stick to “grails console”.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I´ve just started learning GWT and I´m trying to implement http://gwt.google.com/samples/Showcase/Showcase.html#!CwFileUpload and but failing
I just started learning C. What I am trying to right now is that
I just started learning C but I don't understand this part of the code.
I just started learning Common Lisp a few days ago, and I'm trying to
I am a newbie just started exploring Grails so that I can recommend this
Just started learning Scheme. I'm using Dr. Racket as my compiler/interpreter. I need some
Just started learning Rails (3). I am tearing my hair out trying to find
I just started learning Zend. I managed to get the basic working (using zf
I just started learning C++(coming from Java & Python) and am trying to learn
I just started learning SQL a couple of days ago, and I'm trying to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.