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 4070612
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T16:39:00+00:00 2026-05-20T16:39:00+00:00

Recently I deployed my application on Heroku. I’m using Geokit to search events, based

  • 0

Recently I deployed my application on Heroku. I’m using Geokit to search events, based on user’s location.

@events = Event.all(:origin => [@location.lat, @location.lng], :within => 5, :conditions => [“end_date >= ?”, Date.today], :select => “id, created_at, user_id, location, description, permalink, title”, :order => “created_at DESC”)

The above statement is working fine in my local system with mysql database.

But I’m getting error while executing same stmt on Heroku. Please check the below error I’m facing on Heroku.

ActiveRecord::StatementInvalid (PGError: ERROR: function radians(character varying) does not exist
2011-03-20T00:52:23-07:00 app[web.1]: LINE 2: …,COS(0.303256183987648)*COS(1.36963671754269)*COS(RADIANS(fr…
2011-03-20T00:52:23-07:00 app[web.1]: ^
2011-03-20T00:52:23-07:00 app[web.1]: HINT: No function matches the given name and argument types. You might need to add explicit type casts.

Any help would be greatly appreciated.

Thanks,
Kalyan.

  • 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-05-20T16:39:00+00:00Added an answer on May 20, 2026 at 4:39 pm

    As a heads-up, Heroku uses Postgres as the only SQL database backend: http://devcenter.heroku.com/articles/database

    Therefore, your problem is related to these two Q&A:

    Why does Postgresql fail with Geokit like this?

    Rails: Converting from MySQL to PostGres breaks Geokit Distance Calculations?

    In your case, you should add a database migration and change “lat” and “lng” in your location model from “string” (or “text”) to “float”, and then Geokit should work fine with Postgres and Heroku respectively.

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

Sidebar

Related Questions

I recently deployed my ASP.NET 3.5 application to my test server, a newly installed
My deployed application uses ReportViewer (CLR 3.5) to print locally reports. Recently users noticed
I've recently deployed an ASP.NET application to my shiny new VPS and while I'm
I recently bought some webspace with dailyrazor.com. I have deployed an application I have
Recently, we deployed our web-application to a new set of servers. AppServer: Websphere 6.1
I've recently deployed my application on a glassfish installation running on Unix and I'm
Recently we deployed one struts application into production, after sometime if we try to
I just recently deployed a web application (.NET MVC) that has quite a bit
Good afternoon one and all, I've recently deployed a website on a remote server,
I am recently using Uploadify and have deployed it to 3 different servers: Windows,

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.