Forums / Developer / content fetching operator like the SQL "where zipCode LIKE '89%'"

content fetching operator like the SQL "where zipCode LIKE '89%'"

Author Message

Robin de Silva Jayasinghe

Monday 25 October 2004 12:06:46 am

hello,

is there an template-operator which works like the LIKE operator in SQL?

SELECT * FROM cities WHERE zipCode LIKE '89%'"

my intention is to fetch only the content-objects which attribute "zipCode" has a value beginning with "89".

regards,
robin

visit http://www.jayasinghe.de

Björn Dieding@xrow.de

Monday 25 October 2004 4:40:03 pm

Paul Borgermans and his guys from belgium have a modified ezcontentobject.php class that can match contentobject attributes like "like"

http://pubsvn.ez.no

Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs
Looking for hosting? http://hostingezpublish.com
-----------------------------------------------------------------------------
GMT +01:00 Hannover, Germany
Web: http://www.xrow.com/

Robin de Silva Jayasinghe

Monday 25 October 2004 8:28:16 pm

thanks a lot! i'll have a look on that..

und viele gruesse nach hannover ! ;)

visit http://www.jayasinghe.de

Robin de Silva Jayasinghe

Tuesday 26 October 2004 5:26:32 am

hmm.. where exactly can i find the file on that site (http://pubsvn.ez.no)? in the "community" or the "ezPublish" - area? is there something like a search functionality ?

regards,
robin

visit http://www.jayasinghe.de

Tobias Persson

Tuesday 26 October 2004 5:36:05 am

Not sure, but this might be the one??
http://www.ez.no/community/contributions/hacks/more_attribute_filter_operators_and_fetch_by_owner_id

Paul Borgermans

Tuesday 26 October 2004 5:38:05 am

Robin,

You can download a version for the latest stable here:

http://ez.no/community/contributions/hacks/more_attribute_filter_operators_and_fetch_by_owner_id

I will post this also as an "extended attribute filter" which makes this independent of ezp upgrades. I guess most of the functionality will land in the trunk (post 3.5 because of the feature freeze)

hth

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

eZ debug

Timing: Jan 31 2025 08:04:53
Script start
Timing: Jan 31 2025 08:04:53
Module start 'content'
Timing: Jan 31 2025 08:04:53
Module end 'content'
Timing: Jan 31 2025 08:04:53
Script end

Main resources:

Total runtime0.1320 sec
Peak memory usage2,048.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0053 588.1875180.7969
Module start 'content' 0.00530.0054 768.9844102.1016
Module end 'content' 0.01070.1212 871.0859530.3281
Script end 0.1319  1,401.4141 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00312.3223200.0002
Check MTime0.00120.9216200.0001
Mysql Total
Database connection0.00080.597610.0008
Mysqli_queries0.087866.53721410.0006
Looping result0.00110.85811390.0000
Template Total0.120991.610.1209
Template load0.00080.584110.0008
Template processing0.120190.991610.1201
Override
Cache load0.00060.431710.0006
Sytem overhead
Fetch class attribute can translate value0.00090.687010.0009
XML
Image XML parsing0.00030.223410.0003
General
dbfile0.00947.1241200.0005
String conversion0.00000.003830.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs